package cn.com.taiji.oospub.wechat.service.impl;

import cn.com.taiji.oospub.wechat.entity.FoodPriceInfo;
import cn.com.taiji.oospub.wechat.mapper.FoodPriceInfoMapper;
import cn.com.taiji.oospub.wechat.service.IFoodPriceInfoService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author 
 * @since 2020-10-28
 */
@Service
public class FoodPriceInfoServiceImpl extends ServiceImpl<FoodPriceInfoMapper, FoodPriceInfo> implements IFoodPriceInfoService {
    @Autowired
    private FoodPriceInfoMapper foodPriceInfoMapper;

    @Override
    public List<FoodPriceInfo> findPriceByFoodId(String id) {
        QueryWrapper<FoodPriceInfo> queryWrapper=new QueryWrapper<>();
        queryWrapper.eq("Food_Id", id);
        return foodPriceInfoMapper.selectList(queryWrapper);
    }
}
